package com.dc.refactoring._2_在对象之间搬移特性._6_RemoveMiddleMan.oldObject;

/**
 * Description: 移除中间人_Person，去除委托函数或委托类
 * @author: gdc
 * @date: 2020/11/15
 * @version 1.0
 */
public class Person {
    /**
     * 部门引用
     */
    private Department department;

    /**
     * 获取 Person 的领导（委托函数）
     */
    public Person getManager() {
        return department.getManage();
    }
}
